<?php
$this->widget('tlbExcelView', array(
    'dataProvider'=> $dataProvider,
    'id'                   => 'some-grid',
    'grid_mode'            => 'export', // Same usage as EExcelView v0.33
    'title'                => 'KC'.date('YmdHis'),
    'creator'              => '联通华盛',
    'subject'              => mb_convert_encoding('Something important with a date in French: ' . utf8_encode(strftime('%e %B %Y')), 'ISO-8859-1', 'UTF-8'),
    'sheetTitle'           => '合约销售日报'.date('YmdHis'),
//    'landscapeDisplay'     => true, // Default: false
//    'A4'                   => false, // Default: false - ie : Letter (PHPExcel default)
    //'pageFooterText'       => '&RThis is page no. &P of &N pages', // Default: '&RPage &P of &N'
    //'automaticSum'         => true, // Default: false
    'decimalSeparator'     => ',', // Default: '.'
    'thousandsSeparator'   => '.', // Default: ','
    'borderColor'          => '00FF00', // Default: '000000'
    'bgColor'              => 'FFFF00', // Default: 'FFFFFF'
    'textColor'            => 'FF0000', // Default: '000000'
    'rowHeight'            => 20, // Default: 15
    'headerBorderColor'    => 'FF0000', // Default: '000000'
    'headerBgColor'        => 'CCCCCC', // Default: 'CCCCCC'
    'headerTextColor'      => '0000FF', // Default: '000000'
    'headerHeight'         => 20, // Default: 20
    'footerBorderColor'    => '0000FF', // Default: '000000'
    'footerBgColor'        => '00FFCC', // Default: 'FFFFCC'
    'footerTextColor'      => 'FF00FF', // Default: '0000FF'
    'footerHeight'         => 20, // Default: 20
			'columns'=>array(
				array(
					'name'=>'eparchy_code',
                    'value'=>'$data->eparchyCode->eparchy_name',
                    'htmlOptions'=>array('nowrap'=>'nowrap'),
                    'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
                    //'header'=>'日期'
				),
				array(
					'name'=>'depart_code',
					'value'=>'$data->departCode->depart_name',
					'htmlOptions'=>array('nowrap'=>'nowrap'),
					'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
				),
				array(
					'name'=>'num1',
					'value'=>'$data->num1',
					'htmlOptions'=>array('nowrap'=>'nowrap'),
					'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
					'header'=>'(ESS)合约',
				),
				array(
					'name'=>'num3',
					'value'=>'$data->num3',
					'htmlOptions'=>array('nowrap'=>'nowrap'),
					'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
					'header'=>'(易拓)合约',
				),
				array(
					'name'=>'num5',
					'value'=>'$data->num5',
					'htmlOptions'=>array('nowrap'=>'nowrap'),
					'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
					'header'=>'(日报)合约',
				),
				array(
					'name'=>'num2',
					'value'=>'$data->num2',
					'htmlOptions'=>array('nowrap'=>'nowrap'),
					'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
					'header'=>'(ESS)裸机',
				),
				
				array(
					'name'=>'num4',
					'value'=>'$data->num4',
					'htmlOptions'=>array('nowrap'=>'nowrap'),
					'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
					'header'=>'(易拓)裸机',
				),
				
				array(
					'name'=>'num6',
					'value'=>'$data->num6',
					'htmlOptions'=>array('nowrap'=>'nowrap'),
					'headerHtmlOptions'=>array('nowrap'=>'nowrap'),
					'header'=>'(日报)裸机',
				),
			), 
));

?>